package com.zengfa.task.client.service;

import com.zengfa.task.api.model.JobDTO;

public interface JobWorkerService {

	/**
	 * 执行流程任务
	 * @param jobDTO
	 */
	void runFlowTask(JobDTO jobDTO);
	
	/**
	 * 执行同步单任务
	 * @param jobDTO
	 * @param runnable
	 */
	void runTask(JobDTO jobDTO, Runnable runnable);
	
	/**
	 * 执行异步单任务
	 * @param jobDTO
	 * @param runnable
	 */
	void runAsyncTask(JobDTO jobDTO, Runnable runnable);
	
	/**
	 * 停止任务
	 * @param jobId
	 * @param msg
	void stopTask(String jobId, String msg);
	 */
	
}
